<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Calico: calico::sensors::CameraModel Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/x-mathjax-config">
  MathJax.Hub.Config({
    extensions: ["tex2jax.js"],
    jax: ["input/TeX","output/HTML-CSS"],
});
</script>
<script type="text/javascript" async="async" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/MathJax.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Calico
   </div>
   <div id="projectbrief">A visual-inertial calibration library designed for rapid problem construction and debugging.</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="namespacecalico.html">calico</a></li><li class="navelem"><a class="el" href="namespacecalico_1_1sensors.html">sensors</a></li><li class="navelem"><a class="el" href="classcalico_1_1sensors_1_1CameraModel.html">CameraModel</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pub-static-methods">Static Public Member Functions</a> &#124;
<a href="classcalico_1_1sensors_1_1CameraModel-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">calico::sensors::CameraModel Class Reference<span class="mlabels"><span class="mlabel">abstract</span></span></div>  </div>
</div><!--header-->
<div class="contents">

<p>Base class for camera models.  
 <a href="classcalico_1_1sensors_1_1CameraModel.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="camera__models_8h_source.html">camera_models.h</a>&gt;</code></p>
<div class="dynheader">
Inheritance diagram for calico::sensors::CameraModel:</div>
<div class="dyncontent">
<div class="center"><img src="classcalico_1_1sensors_1_1CameraModel__inherit__graph.png" border="0" usemap="#acalico_1_1sensors_1_1CameraModel_inherit__map" alt="Inheritance graph"/></div>
<map name="acalico_1_1sensors_1_1CameraModel_inherit__map" id="acalico_1_1sensors_1_1CameraModel_inherit__map">
<area shape="rect" title="Base class for camera models." alt="" coords="5,209,200,235"/>
<area shape="rect" href="classcalico_1_1sensors_1_1DoubleSphereModel.html" title=" " alt="" coords="248,5,443,47"/>
<area shape="rect" href="classcalico_1_1sensors_1_1ExtendedUnifiedCameraModel.html" title=" " alt="" coords="262,71,429,112"/>
<area shape="rect" href="classcalico_1_1sensors_1_1FieldOfViewModel.html" title=" " alt="" coords="267,136,423,177"/>
<area shape="rect" href="classcalico_1_1sensors_1_1KannalaBrandtModel.html" title=" " alt="" coords="265,201,426,243"/>
<area shape="rect" href="classcalico_1_1sensors_1_1OpenCv5Model.html" title=" " alt="" coords="261,267,429,308"/>
<area shape="rect" href="classcalico_1_1sensors_1_1OpenCv8Model.html" title=" " alt="" coords="261,332,429,373"/>
<area shape="rect" href="classcalico_1_1sensors_1_1UnifiedCameraModel.html" title=" " alt="" coords="268,397,423,439"/>
</map>
<center><span class="legend">[<a href="graph_legend.html">legend</a>]</span></center></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:af2b6c4e6787815273879f81a216bc84d"><td class="memTemplParams" colspan="2">template&lt;typename T &gt; </td></tr>
<tr class="memitem:af2b6c4e6787815273879f81a216bc84d"><td class="memTemplItemLeft" align="right" valign="top">absl::StatusOr&lt; Eigen::Vector2&lt; T &gt; &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classcalico_1_1sensors_1_1CameraModel.html#af2b6c4e6787815273879f81a216bc84d">ProjectPoint</a> (const Eigen::VectorX&lt; T &gt; &amp;intrinsics, const Eigen::Vector3&lt; T &gt; &amp;point) const</td></tr>
<tr class="separator:af2b6c4e6787815273879f81a216bc84d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9724081a0bfba064a65bde83cded5dc9"><td class="memTemplParams" colspan="2">template&lt;typename T &gt; </td></tr>
<tr class="memitem:a9724081a0bfba064a65bde83cded5dc9"><td class="memTemplItemLeft" align="right" valign="top">absl::StatusOr&lt; Eigen::Vector3&lt; T &gt; &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classcalico_1_1sensors_1_1CameraModel.html#a9724081a0bfba064a65bde83cded5dc9">UnprojectPixel</a> (const Eigen::VectorX&lt; T &gt; &amp;intrinsics, const Eigen::Vector2&lt; T &gt; &amp;pixel) const</td></tr>
<tr class="separator:a9724081a0bfba064a65bde83cded5dc9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9384a7307fc7a48d310f361f3b0b4a17"><td class="memItemLeft" align="right" valign="top"><a id="a9384a7307fc7a48d310f361f3b0b4a17"></a>
virtual <a class="el" href="namespacecalico_1_1sensors.html#a1eaf57959273c4ea8dc8899a2e724a2f">CameraIntrinsicsModel</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcalico_1_1sensors_1_1CameraModel.html#a9384a7307fc7a48d310f361f3b0b4a17">GetType</a> () const =0</td></tr>
<tr class="memdesc:a9384a7307fc7a48d310f361f3b0b4a17"><td class="mdescLeft">&#160;</td><td class="mdescRight">Getter for camera model type. <br /></td></tr>
<tr class="separator:a9384a7307fc7a48d310f361f3b0b4a17"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aab677e475ba93fc317ecafc43f4d4711"><td class="memItemLeft" align="right" valign="top"><a id="aab677e475ba93fc317ecafc43f4d4711"></a>
virtual int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcalico_1_1sensors_1_1CameraModel.html#aab677e475ba93fc317ecafc43f4d4711">NumberOfParameters</a> () const =0</td></tr>
<tr class="memdesc:aab677e475ba93fc317ecafc43f4d4711"><td class="mdescLeft">&#160;</td><td class="mdescRight">Getter for the number of parameters for this camera model. <br /></td></tr>
<tr class="separator:aab677e475ba93fc317ecafc43f4d4711"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-static-methods"></a>
Static Public Member Functions</h2></td></tr>
<tr class="memitem:aeda2cd0d8d899ba285a7e610b32fd2a4"><td class="memItemLeft" align="right" valign="top">static std::unique_ptr&lt; <a class="el" href="classcalico_1_1sensors_1_1CameraModel.html">CameraModel</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcalico_1_1sensors_1_1CameraModel.html#aeda2cd0d8d899ba285a7e610b32fd2a4">Create</a> (<a class="el" href="namespacecalico_1_1sensors.html#a1eaf57959273c4ea8dc8899a2e724a2f">CameraIntrinsicsModel</a> camera_model)</td></tr>
<tr class="separator:aeda2cd0d8d899ba285a7e610b32fd2a4"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Base class for camera models. </p>
</div><h2 class="groupheader">Member Function Documentation</h2>
<a id="aeda2cd0d8d899ba285a7e610b32fd2a4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aeda2cd0d8d899ba285a7e610b32fd2a4">&#9670;&nbsp;</a></span>Create()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">std::unique_ptr&lt; <a class="el" href="classcalico_1_1sensors_1_1CameraModel.html">CameraModel</a> &gt; calico::sensors::CameraModel::Create </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="namespacecalico_1_1sensors.html#a1eaf57959273c4ea8dc8899a2e724a2f">CameraIntrinsicsModel</a>&#160;</td>
          <td class="paramname"><em>camera_model</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Factory method for creating a camera model with <code>camera_model</code> type. This method will return a nullptr if an unsupported CameraIntrinsicsModel is passed in. </p>

</div>
</div>
<a id="af2b6c4e6787815273879f81a216bc84d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af2b6c4e6787815273879f81a216bc84d">&#9670;&nbsp;</a></span>ProjectPoint()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">absl::StatusOr&lt; Eigen::Vector2&lt; T &gt; &gt; calico::sensors::CameraModel::ProjectPoint </td>
          <td>(</td>
          <td class="paramtype">const Eigen::VectorX&lt; T &gt; &amp;&#160;</td>
          <td class="paramname"><em>intrinsics</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const Eigen::Vector3&lt; T &gt; &amp;&#160;</td>
          <td class="paramname"><em>point</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Project a point resolved in the camera frame into the pixel space. Top level call invokes the derived class's implementation. </p>

</div>
</div>
<a id="a9724081a0bfba064a65bde83cded5dc9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9724081a0bfba064a65bde83cded5dc9">&#9670;&nbsp;</a></span>UnprojectPixel()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">absl::StatusOr&lt; Eigen::Vector3&lt; T &gt; &gt; calico::sensors::CameraModel::UnprojectPixel </td>
          <td>(</td>
          <td class="paramtype">const Eigen::VectorX&lt; T &gt; &amp;&#160;</td>
          <td class="paramname"><em>intrinsics</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const Eigen::Vector2&lt; T &gt; &amp;&#160;</td>
          <td class="paramname"><em>pixel</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
</div><div class="memdoc">
<p>Inverts the projection model \(\mathbf{P}\) to obtain the bearing vector \(\mathbf{p}_m\) of the pixel location \(\mathbf{p}\). Multiplying the return quantity by the distance of the point gives the location of the resolved in the camera frame. Top level call invokes the derived class's implementation. </p>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>calico/sensors/<a class="el" href="camera__models_8h_source.html">camera_models.h</a></li>
<li>calico/sensors/camera_models.cpp</li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.1
</small></address>
</body>
</html>
